package com.example.k8s.hello.bean.sys.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotBlank;
import lombok.Data;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 角色
 *
 * @author Mark sunlightcs@gmail.com
 */
@Data
@Accessors(chain = true)
@TableName("sys_role")
@Schema(description = "角色")
public class SysRoleEntity implements Serializable {
	private static final long serialVersionUID = 1L;
	
	@TableId
	@Schema(description = "角色ID")
	private Long roleId;

	@NotBlank(message="角色名称不能为空")
	@Schema(description = "角色名称")
	private String roleName;

	@Schema(description = "备注")
	private String remark;
	
	@Schema(description = "创建者ID")
	@TableField(fill = FieldFill.INSERT)
	private Long createUserId;

	@Schema(description = "菜单ID列表")
	@TableField(exist=false)
	private List<Long> menuIdList;
	
	@Schema(description = "创建时间")
	@TableField(fill = FieldFill.INSERT)
	private Date createTime;

	
}
